package org.boge.sharpdoc.dao;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.boge.sharpdoc.bean.DocGroup;
import org.boge.sharpdoc.bean.TreeData;

import java.util.List;

@Mapper
public interface DocGroupDao {
    public DocGroup findById(Integer groupid);

    public List<DocGroup> findChildren(Integer groupid);

    public List<DocGroup> findFirstStep();

    public Integer updateName(DocGroup docGroup);

    public Integer addItem(@Param("belong") Integer belong, @Param("groupname") String groupname);

    public Integer addItem(DocGroup docGroup);

    public Integer deleteItem(DocGroup docGroup);

    public DocGroup findAll();

    public TreeData getTreeData();

    public TreeData treeChildren(Integer groupid);
}